#ifndef __SCENE_H__
#define __SCENE_H__

#include <iostream>
#include <list>
#include "observer.h"
#include "framework.h"
#include "controller/controller.h"
#include "controller/controller_2d.h"
#include "controller/controller3d.h"
#include "controller/top_controller.h"
#include "controller/height_controller.h"
#include "display_list_utils.h"
#include "model/height_model.h"
#include "model/top_model.h"
#include "model/perspective_model.h"
#include "view/top_view.h"
#include "view/height_view.h"
#include "view/perspective_view.h"



class Scene : public IFrameworkCallbacks {
	private:
		static const float day_light_color[4];
		static const float light_position[4];
		static const float day_light_ambient[4];
		static const float night_light_color[4];
		static const float night_light_ambient[4];
		//luces auxiliares
		static const float night_light_color_aux[4][4];
		static const float night_light_pos_aux[4][4];

		static const float material_color[3];

		typedef std::list<Controller*> ControllerList;
		ControllerList controllers;
		bool day;
	public:
		Scene();
		~Scene();

		void clean();
		void init();
		void initLights();
		void reset();

		void display();

		void keyboard(unsigned char key,int x ,int y);
		void processKey(unsigned char key,int x ,int y);
		void mousePressed(int key,int state,int x ,int y);
		void mouseEntry(int state);
		void mouseMotion(int x ,int y);

		void timer(int value);
		void processTimer(int value);

		void reshape(int oldW,int oldH,int w ,int h);
		Controller* getViewportController(int x, int y);

		void swapLights();
};

#endif /* __SCENE_H__ */
